<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Final//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" Content="text/html; charset=Windows-1252">
<TITLE>XYToDisplayPos Method</TITLE>
<link rel="stylesheet" type="text/css" href="help.css">
</HEAD>

<BODY BGCOLOR="#FFFFFF" TEXT="#000000">

<OBJECT TYPE="application/x-oleobject" CLASSID="clsid:1e2a7bd0-dab9-11d0-b93a-00c04fc99f9e">
	<PARAM NAME="Keyword" VALUE="XYToDisplayPos Method">
</OBJECT>

<H1><A NAME="xytodisplaypos_method"></A><B>XYToDisplayPos Method</B></H1>
<HR>

<H2 class="AppliesTo">Applies to</H2>

<P><A HREF="thtmlviewer_component.htm">THtmlViewer</A> component</P>

<H2 class="Declaration">Declaration</H2>

<P>function XYToDisplayPos(X, Y: integer): integer;</P>

<H2 class="Description">Description</H2>

<P>Given X, Y coordinates on the display, XYToDisplayPos finds the display character position for that location.  Dimensions are in pixels relative to the upper left corner of the display.  The character position returned is the same as would be returned by the <A HREF="selstart_property.htm">SelStart</A> property if the mouse were clicked at that location.</P>

<P>XYToDisplayPos returns -1 for X, Y locations where there is no text.</P>

<H2 class="SeeAlso">See Also:</H2>

<P><A HREF="displaypostoxy_method.htm">DisplayPosToXY Method</A></P>

<P><A HREF="selstart_property.htm">SelStart Property</A></P>

<P><A HREF="findsourcepos_method.htm">FindSourcePos Method</A></P>

<P><A HREF="finddisplaypos_method.htm">FindDisplayPos Method</A></P>

</BODY>
</HTML>
